<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>指令</title>
</head>
<body>

    <h3>指令: v-once</h3>

    <div id="root">
        <input type="text" v-model="message" >
        <p v-once>{{ message }}</p>
        <p>{{ message }}</p>
    </div>

    <script src="vue.global.js"></script>

    <script>
        const app = Vue.createApp({
            data(){
                return {
                    message: 'hello,kaifamiao'
                }
            }
        });
        app.mount('#root');
    </script>
    
</body>
</html>